<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml">
		<head>
			<!-- template designed by Marco Von Ballmoos -->
			<title>Docs For Class openSSO_API</title>
			<link rel="stylesheet" href="../media/stylesheet.css" />
			<meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'/>
		</head>
		<body>
			<div class="page-body">			
<h2 class="class-name">Interface openSSO_API</h2>

<a name="sec-description"></a>
<div class="info-box">
	<div class="info-box-title">Description</div>
	<div class="nav-bar">
					<span class="disabled">Description</span> |
															<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
						
					</div>
	<div class="info-box-body">
        		<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">API interface for OpenSSO PHP library.</p>
<p class="description"><p>API interface for OpenSSO PHP library.
 This is an API so we try to not modificate this across the versions. You can use these functions in your application if you include or require the 'open-sso.class.php' file!</p></p>
	<ul class="tags">
				<li><span class="field">author:</span> Pásztor Gergő &lt;<a href="mailto:pairghu@gmail.com">pairghu@gmail.com</a>&gt; from KirDev &lt;kir-dev@sch.bme.hu&gt;</li>
				<li><span class="field">version:</span> 1.0.0</li>
				<li><span class="field">copyright:</span> Copyright (c) 2009, KirDev</li>
				<li><span class="field">link:</span> <a href="http://kir-dev.sch.bme.hu/opensso-phplib/">http://kir-dev.sch.bme.hu/opensso-phplib/</a></li>
				<li><span class="field">license:</span> <a href="http://www.opensource.org/licenses/gpl-license.php">GPL</a></li>
			</ul>
		<p class="notes">
			Located in <a class="field" href="_open-sso.interface.php.html">/open-sso.interface.php</a> (line <span class="field"><a href="../__filesource/fsource_OpenSSO_PHP__open-sso.interface.php.html#a19">19</a></span>)
		</p>
		
				
		<pre></pre>
	
			</div>
</div>




	<a name="sec-method-summary"></a>
	<div class="info-box">
		<div class="info-box-title">Method Summary</span></div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
												<span class="disabled">Methods</span> (<a href="#sec-methods">details</a>)
		</div>
		<div class="info-box-body">			
			<div class="method-summary">
																																																																												
												<div class="method-definition">
											<span class="method-result">(array|bool|multi)</span>
										<a href="#getUserData" title="details" class="method-name">getUserData</a>
											([<span class="var-type">(string)</span>&nbsp;<span class="var-name">$dataName</span> = <span class="var-default">''</span>])
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#http" title="details" class="method-name">http</a>
											(<span class="var-type">void</span>&nbsp;<span class="var-name">0</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#https" title="details" class="method-name">https</a>
											(<span class="var-type">void</span>&nbsp;<span class="var-name">0</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">(bool)</span>
										<a href="#isHttps" title="details" class="method-name">isHttps</a>
											(<span class="var-type">void</span>&nbsp;<span class="var-name">0</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">(bool)</span>
										<a href="#isLogin" title="details" class="method-name">isLogin</a>
											(<span class="var-type">void</span>&nbsp;<span class="var-name">0</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#logIn" title="details" class="method-name">logIn</a>
											(<span class="var-type">void</span>&nbsp;<span class="var-name">0</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#logOut" title="details" class="method-name">logOut</a>
											(<span class="var-type">void</span>&nbsp;<span class="var-name">0</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#setUserData" title="details" class="method-name">setUserData</a>
											(<span class="var-type">(string)</span>&nbsp;<span class="var-name">$data</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#trigger" title="details" class="method-name">trigger</a>
											(<span class="var-type">(string)</span>&nbsp;<span class="var-name">$url</span>)
									</div>
								</div>
		</div>
	</div>		

	
	<a name="sec-methods"></a>
	<div class="info-box">
		<div class="info-box-title">Methods</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
																<a href="#sec-method-summary">Methods</a> (<span class="disabled">details</span>)
						
		</div>
		<div class="info-box-body">
			<A NAME='method_detail'></A>

<a name="methodgetUserData" id="getUserData"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">getUserData</span> (line <span class="line-number"><a href="../__filesource/fsource_OpenSSO_PHP__open-sso.interface.php.html#a103">103</a></span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Get the user's data.</p>
<p class="description"><p>Get the user's data. Logged in usage only.</p></p>
	<ul class="tags">
				<li><span class="field">return:</span> The value of the user's data. If '$dataName' is empty return a single array with all of         the data. If '$dataName' is invalid return (bool)FALSE. Use 'sso_' prefix to access the user's SSO data.</li>
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">(array|bool|multi)</span>
		<span class="method-name">
			getUserData
		</span>
					([<span class="var-type">(string)</span>&nbsp;<span class="var-name">$dataName</span> = <span class="var-default">''</span>])
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">(string)</span>
				<span class="var-name">$dataName</span><span class="var-description">: The name of the user's data. Use 'sso_' prefix to access the user's SSO data.</span>			</li>
				</ul>
		
			
	</div>
<a name="methodhttp" id="http"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">http</span> (line <span class="line-number"><a href="../__filesource/fsource_OpenSSO_PHP__open-sso.interface.php.html#a30">30</a></span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Get HTTP connection, not HTTPS.</p>
<p class="description"><p>Get HTTP connection, not HTTPS. If the user request this 'page' with SSL (HTTPS) this function redirect to the non secured version of the 'page' (HTTP). For example: https://example.org/dir/file.php?var=1 redirect to http://example.org/dir/file.php?var=1</p></p>
	<ul class="tags">
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			http
		</span>
					(<span class="var-type">void</span>&nbsp;<span class="var-name">0</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">void</span>
				<span class="var-name">0</span>			</li>
				</ul>
		
			
	</div>
<a name="methodhttps" id="https"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">https</span> (line <span class="line-number"><a href="../__filesource/fsource_OpenSSO_PHP__open-sso.interface.php.html#a40">40</a></span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Get HTTPS connection, not HTTP.</p>
<p class="description"><p>Get HTTPS connection, not HTTP. If the user request this 'page' without SSL (HTTP) this function redirect to the secured version of the 'page' (HTTPS). For example: http://example.org/dir/file.php?var=1 redirect to https://example.org/dir/file.php?var=1</p></p>
	<ul class="tags">
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			https
		</span>
					(<span class="var-type">void</span>&nbsp;<span class="var-name">0</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">void</span>
				<span class="var-name">0</span>			</li>
				</ul>
		
			
	</div>
<a name="methodisHttps" id="isHttps"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">isHttps</span> (line <span class="line-number"><a href="../__filesource/fsource_OpenSSO_PHP__open-sso.interface.php.html#a50">50</a></span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Is secured, HTTPS connection?.</p>
<p class="description"><p>Is secured, HTTPS connection?. If the user request this 'page' without SSL (HTTP) this function redirect to the secured version of the 'page' (HTTPS). For example: http://example.org/dir/file.php?var=1 redirect to https://example.org/dir/file.php?var=1</p></p>
	<ul class="tags">
				<li><span class="field">return:</span> TRUE if is a HTTPS connection and FALSE is a HTTP connection.</li>
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">(bool)</span>
		<span class="method-name">
			isHttps
		</span>
					(<span class="var-type">void</span>&nbsp;<span class="var-name">0</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">void</span>
				<span class="var-name">0</span>			</li>
				</ul>
		
			
	</div>
<a name="methodisLogin" id="isLogin"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">isLogin</span> (line <span class="line-number"><a href="../__filesource/fsource_OpenSSO_PHP__open-sso.interface.php.html#a93">93</a></span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Is the user logged in?</p>
<p class="description"><p>Is the user logged in?</p></p>
	<ul class="tags">
				<li><span class="field">return:</span> TRUE if the user logged in and FALSE if not.</li>
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">(bool)</span>
		<span class="method-name">
			isLogin
		</span>
					(<span class="var-type">void</span>&nbsp;<span class="var-name">0</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">void</span>
				<span class="var-name">0</span>			</li>
				</ul>
		
			
	</div>
<a name="methodlogIn" id="logIn"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">logIn</span> (line <span class="line-number"><a href="../__filesource/fsource_OpenSSO_PHP__open-sso.interface.php.html#a76">76</a></span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Login the SSO user.</p>
<p class="description"><p>Login the SSO user. Use these function in your login page.
 WARNING: This function is can't garantee that the user logged in! You can always use the 'isLogin();' function after this function to check that the user really logged in.</p></p>
	<ul class="tags">
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			logIn
		</span>
					(<span class="var-type">void</span>&nbsp;<span class="var-name">0</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">void</span>
				<span class="var-name">0</span>			</li>
				</ul>
		
			
	</div>
<a name="methodlogOut" id="logOut"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">logOut</span> (line <span class="line-number"><a href="../__filesource/fsource_OpenSSO_PHP__open-sso.interface.php.html#a85">85</a></span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Logout the SSO user.</p>
<p class="description"><p>Logout the SSO user. Use these function in your logout page.</p></p>
	<ul class="tags">
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			logOut
		</span>
					(<span class="var-type">void</span>&nbsp;<span class="var-name">0</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">void</span>
				<span class="var-name">0</span>			</li>
				</ul>
		
			
	</div>
<a name="methodsetUserData" id="setUserData"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">setUserData</span> (line <span class="line-number"><a href="../__filesource/fsource_OpenSSO_PHP__open-sso.interface.php.html#a113">113</a></span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Set the user's data.</p>
<p class="description"><p>Set the user's data. Store user's data with 'updateUser();' function. Only accept none SSO data! Logged in usage only.</p></p>
	<ul class="tags">
				<li><span class="field">access:</span> public</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			setUserData
		</span>
					(<span class="var-type">(string)</span>&nbsp;<span class="var-name">$data</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">(string)</span>
				<span class="var-name">$data</span><span class="var-description">: Single array of the user's data. Keys represents the data name.</span>			</li>
				</ul>
		
			
	</div>
<a name="methodtrigger" id="trigger"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">trigger</span> (line <span class="line-number"><a href="../__filesource/fsource_OpenSSO_PHP__open-sso.interface.php.html#a64">64</a></span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Trigger.</p>
<p class="description"><p>Trigger. These function create a simple redirect to the login page. Use these function in your trigger page. In default you shouldn't use these function. But if you should put trigger to another page than the default ('trigger.php'), you can do this with this function.</p></p>
	<ul class="tags">
				<li><span class="field">access:</span> public</li>
				<li><span class="field">example:</span> example not found</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			trigger
		</span>
					(<span class="var-type">(string)</span>&nbsp;<span class="var-name">$url</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">(string)</span>
				<span class="var-name">$url</span><span class="var-description">: The URL of the login page. If not setted redirect to the 'loginPage' config. If the this config                 also unsetted create a login action that equal with logIn(); function.</span>			</li>
				</ul>
		
			
	</div>
						
		</div>
	</div>


	<p class="notes" id="credit">
		Documentation generated on Fri, 08 Jan 2010 00:36:03 +0100 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.4.1</a>
	</p>
	</div></body>
</html>